home *** CD-ROM | disk | FTP | other *** search
/ Celestin Apprentice 4 / Apprentice-Release4.iso / Source Code / Libraries / C Internet Config / IC Application Source ƒ / Headers ƒ / IC File Map What.h < prev    next >
Encoding:
C/C++ Source or Header  |  1995-11-30  |  2.8 KB  |  85 lines  |  [TEXT/SPM ]

  1. /*
  2.     IC File Map What.h
  3.     
  4. */
  5.  
  6. #pragma once
  7.  
  8. #ifndef __H_IC_File_Map_What__
  9. #define __H_IC_File_Map_What__
  10.  
  11. enum {
  12.     ditChange=1,ditMainUserItem,ditAdd,ditDelete,ditList,ditSortExtension,ditSortApplication,
  13.     ditSortName,ditDefaults
  14. };
  15.  
  16. enum {
  17.     ditOK=1,ditCancel,ditEditorUserItem,ditEntryName,ditExtension,ditMIMEType,ditAsciiRadio,
  18.     ditBinaryRadio,ditMacintoshRadio,ditType,ditCreator,ditChooseExample,ditApplicationName,
  19.     ditPost,ditPostCreator,ditPostButton,ditNotForIncoming,ditNotForOutgoing,ditAddEditDefaults
  20. };
  21.  
  22. #define kCellHeight 36
  23.  
  24. struct SmallRecordStruct {
  25.     long position;
  26.     Str31 key;
  27. };
  28.  
  29. typedef struct SmallRecordStruct SmallRecord,* SmallRecordPtr;
  30. typedef SmallRecord** SmallArray;
  31. typedef SmallRecord **SmallArrayPtr,*** SmallArrayHandle;
  32.  
  33. #ifdef __cplusplus
  34. extern "C" {
  35. #endif
  36.  
  37. void DimButtons(WindowType wt);
  38. void LDClose(void);
  39. void LDDraw(Handle entries,Boolean select,Rect* r,Cell the_cell,short offset,short datalen,ListHandle lh);
  40. pascal void MyLDEF(short message,Boolean select,Rect* r,Cell the_cell,short offset,short datalen,ListHandle lh);
  41. pascal void FileMapUserItemUpdate(DialogPtr dlg,short item);
  42. OSErr WhatOpenFileMap(WindowType wt,short item);
  43. void SetRadio(DialogPtr modal,short value);
  44. pascal Boolean AddChangeFilter(DialogPtr dlg,EventRecord* event,short* item);
  45. OSErr GetMapEntriesResource(Handle* entries);
  46. StringPtr MapOSType(OSType ot,StringPtr str);
  47. OSType MapStr(StringPtr s);
  48. void DoChooseExample(DialogPtr modal);
  49. Boolean ChoosePost(ICMapEntry* entry);
  50. void SetPostInfo(ICMapEntry* entry,DialogPtr modal);
  51. void SetAllTheStuff(ICMapEntry* entry,DialogPtr modal);
  52. void SetAddEditDefaults(ICMapEntry* entry,DialogPtr modal);
  53. OSErr DoDialog(ICMapEntry* entry);
  54. OSErr DoAddChange(short selection,ICMapEntry* entry,Handle entries,ListHandle lh);
  55. OSErr SetEntriesHandle(WindowType wt,Handle entries);
  56. void QuickSortSmall(SmallArrayHandle small,long l,long r);
  57. void SmallSort(SmallArrayHandle small,long count);
  58.  
  59. /*
  60.     DoSort - Sort the list based on extension, creator, or name.
  61.     
  62.     Unlike the pascal version, I am using an array of pointers to control the sorting.
  63.     Hopefully this would result in a traumatic speed increase when sorting a large list of items,
  64.     assuming I got the translation correct.
  65. */
  66. void DoSort(WindowType wt,short item);
  67. void DoSetDefaults(WindowType wt);
  68. OSErr WhatClickFileMap(WindowType wt,short item,EventRecord* er);
  69. OSErr WhatFlushFileMap(WindowType wt,short item);
  70. OSErr WhatCloseFileMap(WindowType wt,short item);
  71. OSErr WhatActivateFileMap(WindowType wt,short item,Boolean activate);
  72. pascal StringPtr GetFileMapEntryName(ListHandle list,Cell c,StringPtr str);
  73. OSErr WhatKeyFileMap(WindowType wt,short item,EventRecord* er);
  74. OSErr WhatCursorFileMap(WindowType wt,short item,Point pt,short cursid);
  75. void MappingSetSelection(const StringPtr key);
  76.  
  77.  
  78. #ifdef __cplusplus
  79. }
  80. #endif
  81.  
  82. #endif /* __H_IC_File_Map_What__ */
  83.  
  84.  
  85.